package nyist.media.bean.role;

import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import nyist.media.bean.OptionBean;
import nyist.media.entity.admin.Role;

/**
 * @author dcf
 * @date 2018/12/23
 */
@Getter
@Setter
@NoArgsConstructor
public class RoleOptionBean extends OptionBean {

    private static final long serialVersionUID = -1107951443236768823L;

    /**
     * 是否是默认角色
     */
    private boolean roleDef;

    public RoleOptionBean(Role role) {
        setId(role.getId());
        setName(role.getName());
        this.roleDef = role.isRoleDef();
    }
}
